package com.nth.android.ar;

public class ARUtil {

	public static Vector3 origin = new Vector3(0, 0, 0);
	public static Vector3 upVector = new Vector3(0, 1, 0);

	public static float getAngle(float center_x, float center_y, float post_x, float post_y) {
		float tmpv_x = post_x - center_x;
		float tmpv_y = post_y - center_y;
		float d = (float) Math.sqrt(tmpv_x * tmpv_x + tmpv_y * tmpv_y);
		float cos = tmpv_x / d;
		float angle = (float) ((tmpv_y < 0 ? -1 : 1) * Math.toDegrees(Math.acos(cos)));
		return angle;
	}
	
}
